package tsg.laf.eventhorizon;

import tsg.component.Component;
import tsg.component.SquareBorder;
import tsg.graphic.Graphics;

public class EventHorizonSquareBorderUI extends EventHorizonBorderUI
{
	public void paint(Graphics g, Component parent) 
	{
		SquareBorder border = (SquareBorder)parent;
		
		int width 	 	= border.getSize().getWidth();
		int height 		= border.getSize().getHeight();
		int lineWidth 	= border.getLineWidth();
		
		g.setColor(border.getColor());
		
		for(int i=0; i<lineWidth; i++)
		{
			// Draw the Top Line
			g.drawLine(0, 0+i, width, 0+i);
			
			// Draw the Left Line
			g.drawLine(0+i, 0, 0+i, height);
			
			// Draw the Right Line
			g.drawLine(width-i, 0, width-i, height);
			
			// Draw the Bottom Line
			g.drawLine(0, height-i, width, height-i);
		}
	}

}
